﻿using System;
using System.ComponentModel;
using System.Runtime.InteropServices;

namespace Teigha.Core
{
	public class OdGiMaterialTraitsData : IDisposable
	{
		[EditorBrowsable(EditorBrowsableState.Never)]
		public OdGiMaterialTraitsData(IntPtr cPtr, bool cMemoryOwn)
		{
			this.swigCMemOwn = cMemoryOwn;
			this.swigCPtr = new HandleRef(this, cPtr);
		}

		[EditorBrowsable(EditorBrowsableState.Never)]
		public static HandleRef getCPtr(OdGiMaterialTraitsData obj)
		{
			if (obj != null)
			{
				return obj.swigCPtr;
			}
			return new HandleRef(null, IntPtr.Zero);
		}

		~OdGiMaterialTraitsData()
		{
			this.Dispose();
		}

		public virtual void Dispose()
		{
			if (this.swigCPtr.Handle != IntPtr.Zero)
			{
				if (this.swigCMemOwn)
				{
					lock (this.locker)
					{
						if (this.swigCPtr.Handle != IntPtr.Zero && this.swigCMemOwn)
						{
							this.swigCMemOwn = false;
							GlobalsPINVOKE.delete_OdGiMaterialTraitsData(this.swigCPtr);
						}
					}
					this.swigCMemOwn = false;
				}
				this.swigCPtr = new HandleRef(null, IntPtr.Zero);
			}
			GC.SuppressFinalize(this);
		}

		public OdGiMaterialTraitsData() : this(GlobalsPINVOKE.new_OdGiMaterialTraitsData(), true)
		{
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void Assign(OdGiMaterialTraitsData other)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_Assign(this.swigCPtr, OdGiMaterialTraitsData.getCPtr(other));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public bool IsEqual(OdGiMaterialTraitsData other)
		{
			bool result = GlobalsPINVOKE.OdGiMaterialTraitsData_IsEqual(this.swigCPtr, OdGiMaterialTraitsData.getCPtr(other));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public bool IsNotEqual(OdGiMaterialTraitsData other)
		{
			bool result = GlobalsPINVOKE.OdGiMaterialTraitsData_IsNotEqual(this.swigCPtr, OdGiMaterialTraitsData.getCPtr(other));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void ambient(OdGiMaterialColor ambientColor)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_ambient(this.swigCPtr, OdGiMaterialColor.getCPtr(ambientColor));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void diffuse(OdGiMaterialColor diffuseColor, OdGiMaterialMap diffuseMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_diffuse(this.swigCPtr, OdGiMaterialColor.getCPtr(diffuseColor), OdGiMaterialMap.getCPtr(diffuseMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void specular(OdGiMaterialColor specularColor, OdGiMaterialMap specularMap, out double glossFactor)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_specular(this.swigCPtr, OdGiMaterialColor.getCPtr(specularColor), OdGiMaterialMap.getCPtr(specularMap), out glossFactor);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void reflection(OdGiMaterialMap reflectionMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_reflection(this.swigCPtr, OdGiMaterialMap.getCPtr(reflectionMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void opacity(out double opacityPercentage, OdGiMaterialMap opacityMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_opacity(this.swigCPtr, out opacityPercentage, OdGiMaterialMap.getCPtr(opacityMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void bump(OdGiMaterialMap bumpMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_bump(this.swigCPtr, OdGiMaterialMap.getCPtr(bumpMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void refraction(out double refractionIndex, OdGiMaterialMap refractionMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_refraction(this.swigCPtr, out refractionIndex, OdGiMaterialMap.getCPtr(refractionMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double translucence()
		{
			double result = GlobalsPINVOKE.OdGiMaterialTraitsData_translucence(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public double selfIllumination()
		{
			double result = GlobalsPINVOKE.OdGiMaterialTraitsData_selfIllumination(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public double reflectivity()
		{
			double result = GlobalsPINVOKE.OdGiMaterialTraitsData_reflectivity(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public OdGiMaterialTraits.IlluminationModel illuminationModel()
		{
			OdGiMaterialTraits.IlluminationModel result = (OdGiMaterialTraits.IlluminationModel)GlobalsPINVOKE.OdGiMaterialTraitsData_illuminationModel(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public OdGiMaterialTraits.ChannelFlags channelFlags()
		{
			OdGiMaterialTraits.ChannelFlags result = (OdGiMaterialTraits.ChannelFlags)GlobalsPINVOKE.OdGiMaterialTraitsData_channelFlags(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public OdGiMaterialTraits.Mode mode()
		{
			OdGiMaterialTraits.Mode result = (OdGiMaterialTraits.Mode)GlobalsPINVOKE.OdGiMaterialTraitsData_mode(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setAmbient(OdGiMaterialColor ambientColor)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setAmbient(this.swigCPtr, OdGiMaterialColor.getCPtr(ambientColor));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setDiffuse(OdGiMaterialColor diffuseColor, OdGiMaterialMap diffuseMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setDiffuse(this.swigCPtr, OdGiMaterialColor.getCPtr(diffuseColor), OdGiMaterialMap.getCPtr(diffuseMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setSpecular(OdGiMaterialColor specularColor, OdGiMaterialMap specularMap, double glossFactor)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setSpecular(this.swigCPtr, OdGiMaterialColor.getCPtr(specularColor), OdGiMaterialMap.getCPtr(specularMap), glossFactor);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setReflection(OdGiMaterialMap reflectionMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setReflection(this.swigCPtr, OdGiMaterialMap.getCPtr(reflectionMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setOpacity(double opacityPercentage, OdGiMaterialMap opacityMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setOpacity(this.swigCPtr, opacityPercentage, OdGiMaterialMap.getCPtr(opacityMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setBump(OdGiMaterialMap bumpMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setBump(this.swigCPtr, OdGiMaterialMap.getCPtr(bumpMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setRefraction(double refractionIndex, OdGiMaterialMap refractionMap)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setRefraction(this.swigCPtr, refractionIndex, OdGiMaterialMap.getCPtr(refractionMap));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setTranslucence(double value)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setTranslucence(this.swigCPtr, value);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setSelfIllumination(double value)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setSelfIllumination(this.swigCPtr, value);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setReflectivity(double value)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setReflectivity(this.swigCPtr, value);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setIlluminationModel(OdGiMaterialTraits.IlluminationModel model)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setIlluminationModel(this.swigCPtr, (int)model);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setChannelFlags(OdGiMaterialTraits.ChannelFlags flags)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setChannelFlags(this.swigCPtr, (int)flags);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setMode(OdGiMaterialTraits.Mode value)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setMode(this.swigCPtr, (int)value);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setColorBleedScale(double scale)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setColorBleedScale(this.swigCPtr, scale);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double colorBleedScale()
		{
			double result = GlobalsPINVOKE.OdGiMaterialTraitsData_colorBleedScale(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setIndirectBumpScale(double scale)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setIndirectBumpScale(this.swigCPtr, scale);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double indirectBumpScale()
		{
			double result = GlobalsPINVOKE.OdGiMaterialTraitsData_indirectBumpScale(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setReflectanceScale(double scale)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setReflectanceScale(this.swigCPtr, scale);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double reflectanceScale()
		{
			double result = GlobalsPINVOKE.OdGiMaterialTraitsData_reflectanceScale(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setTransmittanceScale(double scale)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setTransmittanceScale(this.swigCPtr, scale);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double transmittanceScale()
		{
			double result = GlobalsPINVOKE.OdGiMaterialTraitsData_transmittanceScale(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setTwoSided(bool flag)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setTwoSided(this.swigCPtr, flag);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public bool twoSided()
		{
			bool result = GlobalsPINVOKE.OdGiMaterialTraitsData_twoSided(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setLuminanceMode(OdGiMaterialTraits.LuminanceMode mode)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setLuminanceMode(this.swigCPtr, (int)mode);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public OdGiMaterialTraits.LuminanceMode luminanceMode()
		{
			OdGiMaterialTraits.LuminanceMode result = (OdGiMaterialTraits.LuminanceMode)GlobalsPINVOKE.OdGiMaterialTraitsData_luminanceMode(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setLuminance(double value)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setLuminance(this.swigCPtr, value);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double luminance()
		{
			double result = GlobalsPINVOKE.OdGiMaterialTraitsData_luminance(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setNormalMap(OdGiMaterialMap normalMap, OdGiMaterialTraits.NormalMapMethod method, double strength)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setNormalMap(this.swigCPtr, OdGiMaterialMap.getCPtr(normalMap), (int)method, strength);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void normalMap(OdGiMaterialMap normalMap, out OdGiMaterialTraits.NormalMapMethod method, out double strength)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_normalMap(this.swigCPtr, OdGiMaterialMap.getCPtr(normalMap), out method, out strength);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public void setGlobalIllumination(OdGiMaterialTraits.GlobalIlluminationMode mode)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setGlobalIllumination(this.swigCPtr, (int)mode);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public OdGiMaterialTraits.GlobalIlluminationMode globalIllumination()
		{
			OdGiMaterialTraits.GlobalIlluminationMode result = (OdGiMaterialTraits.GlobalIlluminationMode)GlobalsPINVOKE.OdGiMaterialTraitsData_globalIllumination(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setFinalGather(OdGiMaterialTraits.FinalGatherMode mode)
		{
			GlobalsPINVOKE.OdGiMaterialTraitsData_setFinalGather(this.swigCPtr, (int)mode);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public OdGiMaterialTraits.FinalGatherMode finalGather()
		{
			OdGiMaterialTraits.FinalGatherMode result = (OdGiMaterialTraits.FinalGatherMode)GlobalsPINVOKE.OdGiMaterialTraitsData_finalGather(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		private object locker = new object();

		private HandleRef swigCPtr;

		protected bool swigCMemOwn;
	}
}
